package cn.bisoft.java.bean.entity;

import java.io.Serializable;



/**
 * This is an object that contains data related to the AwardParameter table.
 * Do not modify this class because it will be overwritten if the configuration file
 * related to this class is modified.
 *
 * @hibernate.class
 *  table="AwardParameter"
 */

public abstract class BaseAwardParameter  implements Serializable {
	private static final long serialVersionUID = 1L;
	public static String REF = "AwardParameter";
	public static String PROP_GAME_ISSUE = "gameIssue";
	public static String PROP_PRICE = "price";
	public static String PROP_ESPECIAL_CODE_AMOUNT = "especialCodeAmount";
	public static String PROP_AWARD_LEVEL = "awardLevel";
	public static String PROP_NOTE = "note";
	public static String PROP_BASE_CODE_AMOUNT = "baseCodeAmount";
	public static String PROP_GAME_ID = "gameId";
	public static String PROP_AWARD_LEVEL_KEY = "awardLevelKey";
	public static String PROP_AWARD_LEVEL_NAME = "awardLevelName";
	public static String PROP_ADDITION_CODE_AMOUNT = "additionCodeAmount";


	// constructors
	public BaseAwardParameter () {
		initialize();
	}

	/**
	 * Constructor for primary key
	 */
	public BaseAwardParameter (java.lang.Integer awardLevelKey) {
		this.setAwardLevelKey(awardLevelKey);
		initialize();
	}

	/**
	 * Constructor for required fields
	 */
	public BaseAwardParameter (
		java.lang.Integer awardLevelKey,
		int gameId,
		int baseCodeAmount,
		short especialCodeAmount,
		short awardLevel,
		int price) {

		this.setAwardLevelKey(awardLevelKey);
		this.setGameId(gameId);
		this.setBaseCodeAmount(baseCodeAmount);
		this.setEspecialCodeAmount(especialCodeAmount);
		this.setAwardLevel(awardLevel);
		this.setPrice(price);
		initialize();
	}

	protected void initialize () {}



	private int hashCode = Integer.MIN_VALUE;

	// primary key
	private java.lang.Integer awardLevelKey;

	// fields
	private int gameId;
	private java.lang.Integer gameIssue;
	private int baseCodeAmount;
	private short especialCodeAmount;
	private short awardLevel;
	private int price;
	private java.lang.String note;
	private short additionCodeAmount;
	private java.lang.String awardLevelName;
	private int levelBonusMoney;



	/**
	 * Return the unique identifier of this class
     * @hibernate.id
     *  generator-class="assigned"
     *  column="AwardLevelKey"
     */
	public java.lang.Integer getAwardLevelKey () {
		return awardLevelKey;
	}

	/**
	 * Set the unique identifier of this class
	 * @param awardLevelKey the new ID
	 */
	public void setAwardLevelKey (java.lang.Integer awardLevelKey) {
		this.awardLevelKey = awardLevelKey;
		this.hashCode = Integer.MIN_VALUE;
	}




	/**
	 * Return the value associated with the column: GameID
	 */
	public int getGameId () {
		return gameId;
	}

	/**
	 * Set the value related to the column: GameID
	 * @param gameId the GameID value
	 */
	public void setGameId (int gameId) {
		this.gameId = gameId;
	}



	/**
	 * Return the value associated with the column: GameIssue
	 */
	public java.lang.Integer getGameIssue () {
		return gameIssue;
	}

	/**
	 * Set the value related to the column: GameIssue
	 * @param gameIssue the GameIssue value
	 */
	public void setGameIssue (java.lang.Integer gameIssue) {
		this.gameIssue = gameIssue;
	}



	/**
	 * Return the value associated with the column: BaseCodeAmount
	 */
	public int getBaseCodeAmount () {
		return baseCodeAmount;
	}

	/**
	 * Set the value related to the column: BaseCodeAmount
	 * @param baseCodeAmount the BaseCodeAmount value
	 */
	public void setBaseCodeAmount (int baseCodeAmount) {
		this.baseCodeAmount = baseCodeAmount;
	}



	/**
	 * Return the value associated with the column: EspecialCodeAmount
	 */
	public short getEspecialCodeAmount () {
		return especialCodeAmount;
	}

	/**
	 * Set the value related to the column: EspecialCodeAmount
	 * @param especialCodeAmount the EspecialCodeAmount value
	 */
	public void setEspecialCodeAmount (short especialCodeAmount) {
		this.especialCodeAmount = especialCodeAmount;
	}



	/**
	 * Return the value associated with the column: AwardLevel
	 */
	public short getAwardLevel () {
		return awardLevel;
	}

	/**
	 * Set the value related to the column: AwardLevel
	 * @param awardLevel the AwardLevel value
	 */
	public void setAwardLevel (short awardLevel) {
		this.awardLevel = awardLevel;
	}



	/**
	 * Return the value associated with the column: Price
	 */
	public int getPrice () {
		return price;
	}

	/**
	 * Set the value related to the column: Price
	 * @param price the Price value
	 */
	public void setPrice (int price) {
		this.price = price;
	}



	/**
	 * Return the value associated with the column: Note
	 */
	public java.lang.String getNote () {
		return note;
	}

	/**
	 * Set the value related to the column: Note
	 * @param note the Note value
	 */
	public void setNote (java.lang.String note) {
		this.note = note;
	}



	/**
	 * Return the value associated with the column: AdditionCodeAmount
	 */
	public short getAdditionCodeAmount () {
		return additionCodeAmount;
	}

	/**
	 * Set the value related to the column: AdditionCodeAmount
	 * @param additionCodeAmount the AdditionCodeAmount value
	 */
	public void setAdditionCodeAmount (short additionCodeAmount) {
		this.additionCodeAmount = additionCodeAmount;
	}



	/**
	 * Return the value associated with the column: AwardLevelName
	 */
	public java.lang.String getAwardLevelName () {
		return awardLevelName;
	}

	/**
	 * Set the value related to the column: AwardLevelName
	 * @param awardLevelName the AwardLevelName value
	 */
	public void setAwardLevelName (java.lang.String awardLevelName) {
		this.awardLevelName = awardLevelName;
	}




	public boolean equals (Object obj) {
		if (null == obj) return false;
		if (!(obj instanceof AwardParameter)) return false;
		else {
			AwardParameter awardParameter = (AwardParameter) obj;
			if (null == this.getAwardLevelKey() || null == awardParameter.getAwardLevelKey()) return false;
			else return (this.getAwardLevelKey().equals(awardParameter.getAwardLevelKey()));
		}
	}

	public int hashCode () {
		if (Integer.MIN_VALUE == this.hashCode) {
			if (null == this.getAwardLevelKey()) return super.hashCode();
			else {
				String hashStr = this.getClass().getName() + ":" + this.getAwardLevelKey().hashCode();
				this.hashCode = hashStr.hashCode();
			}
		}
		return this.hashCode;
	}


	public String toString () {
		return super.toString();
	}

	public int getLevelBonusMoney()
	{
		return levelBonusMoney;
	}

	public void setLevelBonusMoney(int levelBonusMoney)
	{
		this.levelBonusMoney = levelBonusMoney;
	}


}